﻿<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
       "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<link rel="stylesheet" type="text/css" href="style.css">
<meta http-equiv="content-type" content="text/html; charset=utf-8">
</head>
<body>



<?php
include("inc/joomlaInt.php");
include("inc/inc_configuration.php");

if ($jUser==0)
{
	echo "Bitte zuerst einloggen!";
}
else
{
	$icq=$_POST["icq"];
	$gamertag=$_POST["gamertag"];
	
	$q="SELECT * FROM $tbl_ui WHERE userId=$jUser";
	$qe=mysql_query($q);
	$qc=mysql_num_rows($qe);
	
	if ($qc>0)
	{
		$qeo=mysql_fetch_object($qe);
		$id=$qeo->id;
		
		$q="UPDATE $tbl_ui SET gamertag='$gamertag', icq='$icq' WHERE id=$id";
		$qe=mysql_query($q);
		
	}
	else
	{
		$q="INSERT INTO $tbl_ui (gamertag,icq,userId) VALUES('$gamertag','$icq',$jUser)";
		$qe=mysql_query($q);
	}
	
	echo'Sie werden weitergeleitet... <meta http-equiv="refresh" content="0; URL=profil.php?id=',$jUser,'">';
	
}
?>

</body>
</html>